<template>
  <h1>测试一下</h1>
  <el-carousel height="240px" >
    <el-carousel-item v-for="(url,index) in bannerArr" :key="index">
      <img :src="url" style="width: 100%; height: 100%;">
    </el-carousel-item>
  </el-carousel>
</template>

<script setup>
import { ElCarouselItem } from 'element-plus';

import {ref} from "vue";
//1.准备轮播图数组
const bannerArr = ref(["/imgs/banner1.jpg", "/imgs/banner2.jpg", "/imgs/banner3.jpg", "/imgs/banner4.jpg", "/imgs/banner5.jpg"]);
</script>

<style scoped>

</style>
